let mix = require('laravel-mix');

/*
 |--------------------------------------------------------------------------
 | Mix Asset Management
 |--------------------------------------------------------------------------
 |
 | Mix provides a clean, fluent API for defining some Webpack build steps
 | for your Laravel application. By default, we are compiling the Sass
 | file for the application as well as bundling up all the JS files.
 |
 */

mix.js('resources/assets/js/app.js', 'public/js')
    .react('resources/assets/js/home.js','public/js')
   .less('resources/assets/less/app.less', 'public/css')
   .less('resources/assets/less/bootstrap.less', 'public/css');
mix.scripts([
    'public/js/app.js',
    'public/js/jquery-ui.min.js'
],'public/js/all.js');
mix.browserSync({
    proxy: '127.0.0.1',   // apache或iis等代理地址
    port: 80,
    notify: true,        // 刷新是否提示
    watchTask: true,
    open: 'external',
    host: '192.168.1.183',  // 本机ip, 这样其他设备才可实时看到更新
});
